package com.zhifa.zipkin.controller;



import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.client.RestTemplate;

@RestController
public class R {


    @Autowired
    private RestTemplate restTemplate;

    @RequestMapping("/list")
    public Object list() throws Exception {

        return "list-z3"+"---->";
    }
    @RequestMapping("/get")
    public Object get() throws Exception {
        String s1 = "http://localhost:8082/get";

        String forObject = restTemplate.getForObject(s1, String.class);
        return "list-z3-get"+"---->"+forObject;
    }


}
